package com.rockcent.mall.helper;

import com.rockcent.mall.lib.domain.Topic;
import com.rockcent.mall.lib.dto.TopicDto;
import com.rockcent.mall.lib.helper.BaseUserHelper;
import org.springframework.stereotype.Component;

/**
 * Created by zhangjh on 2016/11/15.
 */
@Component
public class TopicHelper  extends BaseUserHelper {

    public Topic chgCtoToDomain(TopicDto dto) {
        Topic topic = new Topic();
        topic.setBackgroundPath(dto.getBackgroundPath());
        topic.setSeqNo(dto.getSeqNo());
        topic.setDescription(dto.getDescription());
        topic.setPic(dto.getPic());
        topic.setTitle(dto.getTitle());

        return topic;

    }
}
